# -*- coding: utf-8 -*-

from pythonmq import QUEUE,TOPIC
from testfuncs import testfunc,testfunc2


python_queue_servers = [
        ('localhost',61613,)
    ]

python_queue_handler = {
        'type': QUEUE,
        'worker': testfunc,
        'auto_acknowledge': True,
        'transactional': False,
        'concurrent': False,
    }

python2_queue_handler = {
        'type': QUEUE,
        'worker': testfunc2,
        'auto_acknowledge': True,
        'transactional': False,
        'concurrent': True,
        'min_pool_size': 5,
        'max_pool_size': 10,
        'custom_headers': {
            'subscribe': {'activemq.prefetchSize':1,},
            'connect':{},
        },
    }

clients = (
        {
            'servers':  python_queue_servers,
            'consumers':
                {
                    'python' : python_queue_handler,
                    'python2' : python2_queue_handler,
                } 
        },
    )
